package com.sun.service.impl;

import com.sun.entity.Student;
import com.sun.mapper.StudentMapper;
import com.sun.service.StudentService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * @author SunRui
 * @description TODO
 * @date 2024/9/24 18:46
 */
@Service
public class StudentServiceImpl implements StudentService {
    @Autowired
    StudentMapper studentMapper;
    @Override
    public int add(Student student) {
        return studentMapper.add(student);
    }

    @Override
    public int delete(int id) {
        return studentMapper.delete(id);
    }

    @Override
    public int update(Student student) {
        return studentMapper.update(student);
    }

    @Override
    public Student select(int id) {
        return studentMapper.select(id);
    }
}
